Housings for electric switchgear and control gear, with a housing cover that can be attached to a housing base body by a lock, are known. The lock has a blocking element displaceably attached to the housing cover and operable by an operating slide connected to it. In the closed position, the locking element engages with a seating face arranged on the housing base body and thus prevents the housing cover from being removed from the housing base body. Because of their size, these conventional locks are difficult to mount on difficult-to-access locations on the housing. Furthermore, there is the risk that the lock might be unintentionally shifted into an open position because of the forward-projecting operating slide, so that in most cases an additional screw closure must be provided on the housing cover.